#include "mainwindow.h"
#include "ui_mainwindow.h"
#include <QDebug>

MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow)
{
    ui->setupUi(this);
    isOK = false;

}

MainWindow::~MainWindow()
{
    delete ui;
}

void MainWindow::on_pushButton_clicked()
{
    if(isOK)
    {
        this->close();
    }

    ScreenWidget *s = new ScreenWidget(isOK);
    s->showFullScreen();
}

void MainWindow::on_checkBox_stateChanged(int arg)
{
    isOK = arg;
}
